#include <stdio.h>
#include "../../src/gtthread.h"

char g_str[] = "hello world\n";

gtthread_t g_th1, g_th2;

void* worker(void* arg)
{
	return (void*)g_str;
}

int main()
{
	volatile int i=0;
	void* ret;

	gtthread_init(1000);

	gtthread_create(&g_th1, worker, NULL);

	for(i=0;i<100000000;i++);

	gtthread_join(g_th1, &ret);

	printf((char*)ret);
}
